#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
int main()
{
  pid_t pid = fork();
  if(pid == 0)
  {
   printf("I am a child process\n");
   execlp("ls","ls","-l",NULL);//进程替换，执行ls命令
   exit(1);
  }
  printf("I am a father process\n");
  printf("hello linux\n");
  return 0;
}
